package com.aier.proxy.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import com.aier.common.common.Constant;

/**
 * Proxy entity. @author MyEclipse Persistence Tools
 */
@SuppressWarnings("serial")
@Entity
@Table(name = "proxy", catalog = "abc")
public class Proxy implements java.io.Serializable {

    // Fields

    private Integer pid;
    // 代理商名称
    private String name;
    // 代理商级别
    private Integer ptype;
    // 代理商帐号
    private String account;
    // 代理商邮箱
    private String email;
    // 代理商电话
    private String phone;
    
    private ProxyCity proxyCity;
   
    // Constructors

    /** default constructor */
    public Proxy() {
    }

    /** minimal constructor */
    public Proxy(Integer pid) {
        this.pid = pid;
    }

    /** full constructor */
    public Proxy(Integer pid, String name) {
        this.pid = pid;
        this.name = name;
    }

    // Property accessors
    @Id
    @Column(name = "pid", unique = true, nullable = false)
    public Integer getPid() {
        return this.pid;
    }

    public void setPid(Integer pid) {
        this.pid = pid;
    }

    @Column(name = "name", length = Constant.num_20)
    public String getName() {
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Column(name = "ptype", nullable = false)
    public Integer getPtype() {
        return ptype;
    }

    public void setPtype(Integer ptype) {
        this.ptype = ptype;
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public ProxyCity getProxyCity() {
        return proxyCity;
    }

    public void setProxyCity(ProxyCity proxyCity) {
        this.proxyCity = proxyCity;
    }
}